package com.joinway.framework.site.beans.view;

import org.hibernate.validator.constraints.NotBlank;
import org.jsondoc.core.annotation.ApiObject;
import org.jsondoc.core.annotation.ApiObjectField;

import com.joinway.framework.bean.BaseBean;

@ApiObject(name="QueryCondition",description="列表查询where条件")
public class QueryCondition extends BaseBean {

	/**
	 * 
	 */
	private static final long serialVersionUID = 1L;

	@NotBlank
	@ApiObjectField(description="列名")
	private String field;
	
	@NotBlank
	@ApiObjectField(description="低区间值")
	private String fromValue;
	
	@ApiObjectField(description="高区间值")
	private String toValue;
	
	@ApiObjectField(description="操作符，默认为like",format="参见com.joinway.framework.site.constants.QueryConstants.Operator")
	private String operator;

	@ApiObjectField(description="字段类型，默认为text",format="参见com.joinway.framework.site.constants.QueryConstants.FieldType")
	private String type;
	
	public String getField() {
		return field;
	}

	public void setField(String field) {
		this.field = field;
	}

	public String getFromValue() {
		return fromValue;
	}

	public void setFromValue(String fromValue) {
		this.fromValue = fromValue;
	}

	public String getToValue() {
		return toValue;
	}

	public void setToValue(String toValue) {
		this.toValue = toValue;
	}

	public String getOperator() {
		return operator;
	}

	public void setOperator(String operator) {
		this.operator = operator;
	}

	public String getType() {
		return type;
	}

	public void setType(String type) {
		this.type = type;
	}
	
	
}

